
<%@page import="com.biz.ProductBizImpl"%>
<%@page import="com.entity.Product"%>
<%@ page language="java" import="java.util.*" pageEncoding="UTF-8"%>
<%@include file="/admin/do/checklogin.jsp" %>
<%
	request.setCharacterEncoding("utf-8");
	Product p=new Product();
	p.setId(Integer.parseInt(request.getParameter("id")));
	
	p.setPname(request.getParameter("pname"));
	p.setPrice(Double.parseDouble(request.getParameter("price")));
	p.setStock(Integer.parseInt(request.getParameter("stock")));
	p.setComments(request.getParameter("comments"));
	p.setKind(Integer.parseInt(request.getParameter("kind")));
	if(new ProductBizImpl().modPro(p)==0){
%>
	<script>alert("修改失败");location='../modPro.jsp';</script>
<%
	}
%>
<script>location='../showPro.jsp';</script>